package functional_programming;

class This{
    void two(int i, double d) {
        System.out.println("two");
    }
    void three(int i, double d, String s) {        System.out.println("three");
    }
    void four(int i, double d, String s, char c) {        System.out.println("four");
    }
}

interface TwoArgs{
    void call2(This athis, int i, double d);
}
interface ThreeArgs{
    void call2(This athis, int i, double d, String s);
}
interface FourArgs{
    void call2(This athis, int i, double d, String s, char c);
}


public class MultiUnbound {

    public static void main(String[] args) {
        This aThis = new This();
        TwoArgs twoArgs = This::two;
        ThreeArgs threeArgs = This::three;
        FourArgs fourArgs = This::four;
        twoArgs.call2(aThis,1,2);
        threeArgs.call2(aThis,1,2,"sdf");
        fourArgs.call2(aThis,1,2,"dsf",'v');
    }
}
